// 导入base.less
@import url(base.less);
// 设置基准值变量
@baseSize: 3.75vmin;
.suspension {
  position: fixed;
  // 固定定位必须有宽度
  width: 100%;
  top: 0;
  left: 0;
  // 因为下面也有定位，翻动的时候会压住这个固定定位
  // 所以往上提
  z-index: 999;
  background-color: #fff;
  .navbar {
    display: flex;
    justify-content: space-between;
    padding: 0 (12 / @baseSize) 0 (18 / @baseSize);
    height: (44 / @baseSize);
    align-items: center;
    .logo {
      i {
        font-size: (28 / @baseSize);
        color: #fb7299;
      }
    }

    .right {
      display: flex;
      .search {
        color: #ccc;
        i {
          font-size: (22 / @baseSize);
        }
      }
      .face {
        overflow: hidden;
        width: (24 / @baseSize);
        height: (24 / @baseSize);
        border-radius: 50%;
        margin: 0 (20 / @baseSize);
      }
      .app-btn {
        width: (72 / @baseSize);
        height: (24 / @baseSize);
      }
    }
  }

  // 频道
  .channel-menu {
    display: flex;
    height: (40 / @baseSize);
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e7e7e7;
    // tabs
    .tabs {
      flex: 1;
      overflow: hidden;
      .tabs-list {
        display: flex;
        position: relative;
        a {
          // 文字不换行
          white-space: nowrap;
          padding: 0 (16 / @baseSize);
          font-size: (14 / @baseSize);
          height: (40 / @baseSize);
          line-height: (40 / @baseSize);
        }
        .line {
          position: absolute;
          left: (16 / @baseSize);
          bottom: 0;
          width: (28 / @baseSize);
          height: (2 / @baseSize);
          background-color: #fb7299;
        }
      }
    }
    .after {
      position: relative;
      width: (40 / @baseSize);
      height: (39 / @baseSize);
      line-height: (39 / @baseSize);
      text-align: center;
      background-color: #fff;
      color: #ccc;
      i {
        font-size: (20 / @baseSize);
      }
    }
  }
}

// 主体模块
.m-home {
  padding: (85 / @baseSize) (5 / @baseSize) 0;
  .vedio-list {
    display: flex;
    // 弹性盒子换行
    flex-wrap: wrap;
    .vedio-item {
      width: 50%;
      padding: (8 / @baseSize) (5 / @baseSize);

      .card {
        position: relative;
        height: (97 / @baseSize);
        .count {
          position: absolute;
          bottom: 0;
          left: 0;
          // 绝对定位的大小取决于内容的大小，所以要加宽度才能显示、
          // 绝对定位如果没有指定width，会显示空白
          width: 100%;
          height: (27 / @baseSize);

          display: flex;
          justify-content: space-between;
          align-items: center;
          font-size: (12 / @baseSize);
          color: #fff;
          // 背景颜色渐变
          background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, .5));
        }
      }

      .title {
        // 超过两行显示省略号
        overflow: hidden;
        text-overflow: ellipsis;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;

        margin-top: (5 / @baseSize);
      }
    }
  }
}

// 底部模块
.app {
  position: fixed;
  left: 0;
  bottom: (30 / @baseSize);
  width: 100%;
  height: (38 / @baseSize);
  .btn-app {
    margin: 0 (20 / @baseSize);
    height: (38 / @baseSize);
    border-radius: (19 / @baseSize);
    text-align: center;
    line-height: (38 / @baseSize);
    // width: 100%;
    color: #fff;
    background-color: #fb7299;
  }
}